The present invention relates to an information processor and an information processing method and, more particularly, to an improved information processor and information processing method for downloading a program via digital broadcasting.
In recent years, with the diversification of broadcasting systems, an apparatus that is connected to a television receiver and provides various functions, i.e., an STB has come along for receiving a new broadcasting method. Especially, with the start of the digital broadcasting, an apparatus which receives Electronic Program Guide (hereinafter, referred to as EPG) information that is text data, hyper text data or the like for guiding programs and is transmitted together with a digital broadcast signal, by using the STB, and displays the EPG information on a screen has been known.
This type of information processor obtains digital information such as EPG from a broadcast signal, while there are some processors that receive a new program which is superimposed on the broadcast signal and transmitted and update an old program, thereby updating the functions so as to correspond to newly coming broadcast services or the like.
In these information processors, data or a program that is received by the STB is stored in a memory. However, when abnormal conditions such as a power failure and a bug in a program occur during the download, memory contents may be destroyed and thus the system may not operate normally.
Accordingly, a backup of the program is retained in a nonvolatile memory such as an electrically erasable and programmable ROM (hereinafter, referred to as EEPROM), and when the program is resumed the backed-up program is taken out from the EEPROM to set the memory contents again.
This kind of information processor includes two nonvolatile memories to store a pre-update program in one memory as a backup and store an update-version program that is being downloaded in the other memory. To be more specific, when two memories are included, the program is stored alternately in the two memories every time the program is updated. When the information processor includes two nonvolatile memories as described above, even when an error or power failure occurs during writing of a program, the program can be restarted because the backup program is stored.
In this conventional information processor, when the new program is successfully downloaded, the old program is left as the backup program for the time being, but there is a high possibility that the old program is not used thereafter. As cases where the old program is used, a case where some fault occurs in the new program during activation of the program and then the old program is read out and used, and the like are conceivable. However, when the new program operates satisfactorily, the old program is never used.
As described above, in the conventional information processor, it is required that a nonvolatile memory having a capacity twice as much as a program should be used as countermeasures against abnormal conditions during writing of the program which rarely occur, such as the occurrence of an error and power failure, whereby the system has quite a low memory efficiency.
It is an object of the present invention to provide an information processor and an information processing method, which can reduce a memory capacity required for backup of a program and utilize a free space in the memory as a cache area of EPG.
Other objects and advantages of the present invention will become apparent from the detailed description and specific embodiments described are provided only for illustration since various additions and modifications within the spirit and scope of the invention will be apparent to those of skill in the art from the detailed description.
According to a 1st aspect of the present invention, there is provided an information processor comprising: a program obtaining means for obtaining a program; a program storage means having plural storage areas and storing the program obtained by the program obtaining means in any of the plural storage areas; a program execution means for executing the program; a selection information updating means for storing execution memory information indicating a storage area which contains a program to be executed by the program execution means, compression information indicating compression states of programs stored in the storage areas, and memory relation information indicating a relation of the plural storage areas; a program execution area switching means for selecting one of the storage areas on the basis of the execution memory information; a storage area switching means for selecting one of the storage areas on the basis of the information in the memory information storage area; a program writing means for writing the program; a program compression means for compressing the program; a program restoration means for restoring the program compressed by the program compression means; and a memory information updating means for updating information stored in the selection information updating means. Therefore, a free space in a memory can be allocated to input of other data, whereby it can be utilized efficiently.
According to a 2nd aspect of the present invention, in the information processor of the 1st aspect, the program execution means executes a program stored in the storage area which is selected by the program execution area switching means on the basis of the execution memory information. Therefore, the program execution means can always select a storage area in which a program of the latest version is stored, and execute the latest version program.
According to a 3rd aspect of the present invention, in the information processor of the 1st or 2nd aspect, the program writing means writes the program obtained by the program obtaining means in the storage area which is selected by the storage area switching means on the basis of the execution memory information and the memory relation information. Therefore, a newly obtained program can be written in a memory that is not being used at present.
According to a 4th aspect of the present invention, in the information processor of any of the 1st to 3rd aspects, the program compression means compresses a program stored in the storage area which is selected by the storage area switching means on the basis of the execution memory information, the compression information and the memory relation information, and the program writing means writes the compressed program in the same storage area as said storage area. Therefore, a program stored in a memory that is not being used at present can be compressed, and a generated free space can be allocated to input of other data, whereby the memory can be utilized effectively.
According to a 5th aspect of the present invention, in the information processor of the 4th aspect, the program restoration means restores the compressed program stored in the storage area which is selected by the storage area switching means on the basis of the execution memory information, the compression information and the memory relation information, and the program writing means writes the restored program in the same storage area as said storage area. Therefore, when an error occurs while an activated program is being executed or when an error occurs while a program is being updated, a compressed program can be restored and executed.
According to a 6th aspect of the present invention, in the information processor of any of the 1st to 5th aspects, the program storage means is a nonvolatile memory. Therefore, when other information is written to effectively use a free space in a memory, that information can be stored without power consumption.
According to a 7th aspect of the present invention, in the information processor of any of the 1st to 4th aspects, a free space in the storage area, which is obtained by compressing the program by the program compression means, is used as a cache area for an electronic program guide. Therefore, the EPG or data broadcast can be utilized immediately after the power is turned on without a latency time.
According to an 8th aspect of the present invention, there is provided an information processing method comprising: a program obtaining step of obtaining a program; a program storage step of storing the program obtained in the program obtaining step in any of plural storage areas; a program execution step of executing the program; a memory information storage step of storing execution memory information indicating a storage area which contains a program to be executed in the program execution step, compression information indicating compression states of programs stored in the storage areas, and memory relationship information indicating a relation of the plural storage areas; a program execution area switching step of selecting one of the storage areas on the basis of the execution memory information; a program storage area switching step of selecting one of the storage areas on the basis of the information stored in the memory information storage step; a program writing step of writing the program; a program compression step of compressing the program; a program restoration step of restoring the program compressed in the program compression step; and a memory information updating step of updating the information stored in the memory information storage step. Therefore, a free space in a memory can be allocated to input of other data, whereby it can be utilized effectively.
According to a 9th aspect of the present invention, in the information processing method of the 8th aspect, in the program execution step, a program stored in the storage area which is selected in the program execution area switching step on the basis of the execution memory information is executed. Therefore, in the program execution step, a storage area in which a program of the latest version is stored can be always selected and the latest version program can be executed.
According to a 10th aspect of the present invention, in the information processing method of the 8th or 9th aspect, in the program writing step, the program obtained in the program obtaining step is written in the storage area which is selected in the storage area switching step on the basis of the execution memory information and the memory relation information. Therefore, a newly obtained program can be written in a memory that is not being used at present.
According to an 11th aspect of the present invention, in the information processing method of any of the 8th to 10th aspects, in the program compression step, a program stored in the storage area which is selected on the basis of the execution memory information, the compression information and the memory relation information in the storage area switching step of selecting one of the storage areas is compressed, and in the program writing step, the compressed program is written in the same storage area as said storage area. Therefore, a free space in a memory can be allocated to input of other data, whereby the memory can be utilized effectively.
According to a 12th aspect of the present invention, in the information processing method of the 11th aspect, in the program restoration step, the program compressed in the storage area which is selected in the storage area switching step on the basis of the execution memory information, the compression information and the memory relation information is restored, and in the program writing step, the restored program is written in the same storage area as said storage area. Therefore, when an error occurs while an activated program is being executed or when an error occurs while a program is being updated, a compressed program can be restored and executed.
According to a 13th aspect of the present invention, there is provided a computer-readable storage medium which contains a program for making a computer implement: a program obtaining process for obtaining a program; a program storage process for storing the program obtained in the program obtaining process in any of plural storage areas; a program execution process for executing the program; a memory information storage process for storing execution memory information indicating a storage area which contains a program to be executed in the program execution process, compression information indicating compression states of programs stored in the storage areas, and memory relation information indicating a relation of the plural storage areas; a program execution area switching process for selecting one of the storage areas on the basis of the execution memory information; a storage area switching process for selecting one of the storage areas on the basis of the information stored in the memory information storage process; a program writing process for writing the program; a program compression process for compressing the program; a program restoration process for restoring the program compressed in the program compression process; and a memory information updating process for updating the information stored in the memory information storage process. Therefore, respective processes of the present invention can be easily implemented in other information processor that includes plural storage areas, by transporting this storage medium.